libxl: Call to open() must specify mode with O_CREAT.
authorKeir Fraser <keir.fraser@citrix.com>
Mon, 9 Nov 2009 22:41:23 +0000 (22:41 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Mon, 9 Nov 2009 22:41:23 +0000 (22:41 +0000)
Signed-off-by: Keir Fraser <keir.fraser@citrix.com>
tools/libxl/libxl.c

index 05f136ae38857b28751dd533ed70d73fdf753c33..dac06c9881da8fadeadf46ad722a34eacc2e9810 100644 (file)
@@ -509,7 +509,7 @@ int libxl_create_device_model(struct libxl_ctx *ctx,
         rename(logfile, logfile_new);
     }
     logfile = libxl_sprintf(ctx, "/var/log/xen/qemu-dm-%s.log", info->dom_name);
-    logfile_w = open(logfile, O_WRONLY|O_CREAT);
+    logfile_w = open(logfile, O_WRONLY|O_CREAT, 0644);
     null = open("/dev/null", O_RDONLY);
     pid = libxl_exec(ctx, null, logfile_w, logfile_w, info->device_model, args);
     close(null);